package com.example.demo.entity.constants;

/**
 * @Author: zcb
 * @Description:
 * @Date: 2021/10/21
 */
public class AnotherThread extends Thread{
    public volatile boolean running = true;

    @Override
    public void run() {
        System.out.println("another线程启动");
        int n = 0;
        while (running){
            System.out.println("another " + n);
        }
        System.out.println("another线程执行完毕");
    }
}
